package com.qcxy.gzy.activity;

import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.TextView;

import com.qcxy.gzy.activity.base.HiddenActivity;
import com.qxcy.gzy.util.SPUtils;

public class ReportActivity extends HiddenActivity implements OnClickListener {

	private TextView mTrainNumber;
	private TextView mTrainTime;
	private TextView mTrainCalorie;

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_report);

		findViewById(R.id.iv_back).setOnClickListener(this);
		mTrainNumber = (TextView) findViewById(R.id.report_number);
		mTrainTime = (TextView) findViewById(R.id.report_time);
		mTrainCalorie = (TextView) findViewById(R.id.report_calorie);

		mTrainNumber.setText(SPUtils.getValueFromSharedFile(this, "Train_Number", "0"));
		mTrainTime.setText(SPUtils.getValueFromSharedFile(this, "Train_Time", "0"));
		mTrainCalorie.setText(SPUtils.getValueFromSharedFile(this, "Train_Calorie", "0.0"));
	}

	@Override
	public void onClick(View v) {
		switch (v.getId()) {
		case R.id.iv_back:
			onBackPressed();
			break;
		default:
			break;
		}
	}
}